//
//  NPDefine.h
//  newProject
//
//  Created by Mac mini on 2017/10/11.
//  Copyright © 2017年 zt. All rights reserved.
//

#ifndef NPDefine_h
#define NPDefine_h
#import <sys/utsname.h>
/*
 *  size
 */

/*NSString*platform = [NSString stringWithCString: systemInfo.machine encoding:NSASCIIStringEncoding];

if([platform isEqualToString:@"iPhone10,3"]) return@"iPhone X";

if([platform isEqualToString:@"iPhone10,6"]) return@"iPhone X";
*/

#if __IPHONE_OS_VERSION_MIN_REQUIRED >=__IPHONE_7_0
#define STATUE_BAR_HEIGHT CGRectGetHeight([UIApplication sharedApplication].statusBarFrame)
#define Height [UIScreen mainScreen].bounds.size.height
#define navHeight 44.0
#else
#define Height [UIScreen mainScreen].bounds.size.height-20
#define navHeight 44.0
#endif



#define NAV_SINGLE_HEIGHT 44
#define NAV_HEIGHT  (44+CGRectGetHeight([UIApplication sharedApplication].statusBarFrame)) //64
#define TABBAR_HEIGHT  self.tabBarController.tabBar.frame.size.height
            //49    // iphone X    85

#define bannerHeight 230


#define SCREEN_H [UIScreen mainScreen].bounds.size.height
#define SCREEN_W [UIScreen mainScreen].bounds.size.width
#define MIDDLE_VIEW_H SCREEN_H - NAV_HEIGHT - TABBAR_HEIGHT


#define SafeAreaTopHeight (SCREEN_H == 812.0 ? 88 : 64)



#define MIN_FONT [UIFont systemFontOfSize:13]
#define BASE_FONT [UIFont systemFontOfSize:14]
#define MIDDLE_FONT [UIFont systemFontOfSize:15]
#define BIG_FONT [UIFont systemFontOfSize:16]
#define SUPER_BIG_FONT [UIFont systemFontOfSize:17]
#define FILTER_STRING(str) str ? str : @""   //字符串

/*
 *  color
 */

#define STORE_ID @"1" //线网1，本地8 //  //24  德联    19  小羊测试  40 上海


#define RGB(r,g,b,a) [UIColor colorWithRed:r/255.0f green:g/255.0f blue:b/255.0f alpha:a]
#define HEXCOLOR(rgbValue) [UIColor colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 green:((float)((rgbValue & 0xFF00) >> 8))/255.0 blue:((float)(rgbValue & 0xFF))/255.0 alpha:1.0]

#define PUBLIC_BACK_GROUND_COLOR RGB (242,242,242,1)
#define PUBLIC_PRICE_COLOR HEXCOLOR(0xff5468)//[UIColor colorWithRed:250/255.0f green:106/255.0f blue:133/255.0f alpha:1]
#define PUBLIC_PINK_COLOR  HEXCOLOR(0xff5468)//[UIColor colorWithRed:250/255.0f green:106/255.0f blue:133/255.0f alpha:1]
#define PUBLIC_MAIN_BTN_COLOR RGB (0,160,237,1)
#define PUBLIC_LINE_COLOR RGB (214,214,214,1).CGColor


#define USERDEF  [NSUserDefaults standardUserDefaults]
#define USERDEF_SET_OBJ(obj,key) [[NSUserDefaults standardUserDefaults] setObject:obj forKey:key]


#define USERDEF_SET_VALUE(value,key) [[NSUserDefaults standardUserDefaults] setObject:value forKey:key]

#define USERDEF_GET_OBJ(key) [[NSUserDefaults standardUserDefaults]objectForKey:key]
#define USERDEF_GET_VALUE(key) [[NSUserDefaults standardUserDefaults]valueForKey:key]


#define FORMATTER @"YYYY-MM-dd HH:mm:ss"
#define PlaceholderPicName @"commodityPlaceholder"
#define commodityPlaceholderPicName @"launch"
#define KEFU_PHONE @"4008382016"   //客服电话
#define APP_STORE_ID @"1330544141"   //appStore appID

//key  and Notifi
#define LOGIN_STATUS       @"LOGIN_STATUS"
#define NOTIFY_ORDER_NUM_CHANGE @"NOTIFY_ORDER_NUM_CHANGE" //订单状态数量改变（对订单操作成功）
#define PAY_RESULT_NOTIFY @"PAY_RESULT_NOTIFY" //支付结果
#define PAY_SUCCESS_NOTIFY @"PAY_SUCCESS_NOTIFY"  //支付成功通知
#define COMMENT_COMMODITY_SUCCESS_NOTIFY @"COMMENT_COMMODITY_NOTIFY" //评论成功通知
#define ORDER_STATUS_CHANGE @"ORDER_STATUS_CHANGE"
#define CHANGE_USERINFO_SUCCESS @"change_userInfo_success" //修改个人信息
#define PUSH_NEW_NOTIFY @"push_new_notify"   //新消息推送通知
#define VIP_GRADE @"vip_grade"   //升降级

#define PUSH_MSG @"pushMsg"  //消息推送本地存储字段
#define USER_INFO @"userInfo"  //个人信息
#define BADGE_NUM @"badge_num"
#define WX_PAY @"wxPayResult"
#define ALI_PAY @"aliPayResult"

#define WX_AppSecret @"8a887d8f5b06c32096efb40dc9372a47"  //微信 AppSecret
//#define WX_AppId @"wx3c0283ffb560d1db"   //geren
#define WX_AppId @"wx1a6791bd778d58a2"   //dianbaobei

#define TENCENT_AppId @"1106699128"   //   腾讯apiId

typedef enum NSUInteger{
    zfb_pay,
    wx_pay,
    
}PAY;   //支付方式

#define JPUSH_appKey @"9ddcdbafc80fa95d657ff9b4"// @"5a35d92daf0d832a00053f75"

#define AliPush_appKey @"24785590"   //阿里推送key
#define AliPush_appSecret @"135e256226d69e3b76c4d87ceb47bd4d" //appSecret

//  支付宝支付
#define PARTNER @"2088521074869374"
#define SELLER  @"njdbaby@163.com"
//商户私钥，自助生成
#define PartnerPrivKey @"MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBALfiU8F/vaFOyG0PT98srczPIGE+ExxQ3tP+T0UKeSOWTQzKjQB9GnGD1UTfpKcYMCZApe7yjrnYXEZUkGYsDa1QU1Gnig50YNS0fPxWgeBdGDtaL5NdspBKyZbMHNFxnyTOCUC6UNAq8cKxK6A94Jbz/L04OOr3czJN3jtoU687AgMBAAECgYBpOSvwaCadLbXnIoH0FV8G+edvfdP1uhkoejfmLA4R3SoODcIN64i8OFJL7SYNL/wth4TsbQRbOIHlBPL0ZHUWJbcr5b7QbfXKqk9NYYzAVx4gu8p3FCJiXImhOznTrX0bGqs5ApI7k8wOUqiN1NjvDHF64EBTpeTv0duGwtfGgQJBANkuLyf6tyH7EQgqXazWfdRgBy8hsk2Ats7vO5yEYmYylzRxVnKVBftwP8E9Y8zn4EkAZ+psvE4VN6gyvjcrr+ECQQDYwI8EPqcrsNzxg6z6gXHhZ1cljsR4ehwBtAHyV7bZLVZnbnfRc9prFp/ZO+cFYj+3jl26uTgwiZ1hesW2TnKbAkEAvbjFwxQXFR1BlLOF364EgBlfTUIPg/r0N7PvjFxtpT9+rXZxAWnDrxIw77uUSnUpjjxHixdwLHoGg+3IE2QboQJAEzcu9p9fTp5FWBvmT+b944+3yBqaDFw282ez7HoeOa6tREok0SrGKEw/K5EF8BI/t9QlNxKIirUIgMXTlU/rFQJAHYKfRL8CVI2uMzfE3PU9vbyw3/4rvBZWqCcBr+ns1uUIa9LkE6NGaEYtIajdpe70dVfkuwlOMmAaELQkN3fauw=="

//支付宝公钥（不是自己生成的）
//#define AlipayPubKey   @"MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCJQ5o3hSgV7WP8KcfX+ECyQSyaqCfAg8yb0o+8Gnp6LUbz+LX+ZgmTDC9+xArWd6BAUju5SNmn9fmY5ho4yqnhcCgYhJwjEjhJu/yOt7kV60r/wFhwe0qyFnQFCPgeZq8ZiZ3SNAHwh1mSWHnBjHmBJQzfSGmw1GqsGJltY0i2EwIDAQAB"

//银行卡等加密公钥
#define BANKCARD_PUBLIC_KEY @"MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCoGq2TObGOeJWd9uginppqm4N8L+tt1tVtAyYq1K7ehHJGyiZVtN4RXX3XR3yMz4yRGPEb+oTqrLCYzmw6W8sps/pJtEgAp8KIvh7qnr3HpBTIR4tZ5Kw8c/p3bSqcUla87ycvPetTsvF2MelzuvYo3Uwi3dOhJwZyGuGlwVgG8wIDAQAB"

#define BANKCARD_PRI_KEY @"MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBAKgarZM5sY54lZ326CKemmqbg3wv623W1W0DJirUrt6EckbKJlW03hFdfddHfIzPjJEY8Rv6hOqssJjObDpbyymz+km0SACnwoi+HuqevcekFMhHi1nkrDxz+ndtKpxSVrzvJy8961Oy8XYx6XO69ijdTCLd06EnBnIa4aXBWAbzAgMBAAECgYBXT5vtxt5w6DKVnCNPr972FhXBz8XRA+9QMn2Fa3fz/Qi5uc8V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